package com.dchh.android.suverynew.presenter.impl;

import com.dchh.android.suverynew.common.ICommonModelListener;
import com.dchh.android.suverynew.module.http.ICommonModule;
import com.dchh.android.suverynew.module.http.impl.CommonModule;
import com.dchh.android.suverynew.presenter.ICommonPresenter;
import com.dchh.android.suverynew.view.ICommonView;
import com.dhcc.android.base.utils.version.UpdataInfo;

/**
 * Created by eric on 2016/8/3.
 */
public class CommonPresenter implements ICommonPresenter, ICommonModelListener {
    private ICommonView mCommonView;
    protected ICommonModule mCommonModule;

    public CommonPresenter(ICommonView mCommonView) {
        this.mCommonView = mCommonView;
        this.mCommonModule = new CommonModule(this);
    }

    @Override
    public void onStartLoad() {
        this.mCommonView.showProgressDialog();
    }

    @Override
    public void onError(String errMsg) {
        this.mCommonView.onError(errMsg);
    }

    @Override
    public void onCompleted() {
        this.mCommonView.closeProgressDialog();
    }

    @Override
    public void onCheckVersionSuccess(UpdataInfo updataInfo) {

    }
}
